load("@io_bazel_rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "go_default_library",
    srcs = [
        "consts.go",
        "error.go",
        "formatter.go",
        "json.go",
        "label.go",
        "pointer.go",
        "scheduled_workflow.go",
        "service.go",
        "string.go",
        "template_util.go",
        "tgz.go",
        "time.go",
        "uuid.go",
        "workflow.go",
    ],
    importpath = "github.com/kubeflow/pipelines/backend/src/common/util",
    visibility = ["//visibility:public"],
    deps = [
        "//backend/api:go_default_library",
        "//backend/src/crd/pkg/apis/scheduledworkflow:go_default_library",
        "//backend/src/crd/pkg/apis/scheduledworkflow/v1beta1:go_default_library",
        "@com_github_argoproj_argo//pkg/apis/workflow/v1alpha1:go_default_library",
        "@com_github_cenkalti_backoff//:go_default_library",
        "@com_github_ghodss_yaml//:go_default_library",
        "@com_github_go_openapi_runtime//:go_default_library",
        "@com_github_go_openapi_strfmt//:go_default_library",
        "@com_github_golang_glog//:go_default_library",
        "@com_github_google_uuid//:go_default_library",
        "@com_github_pkg_errors//:go_default_library",
        "@io_bazel_rules_go//proto/wkt:timestamp_go_proto",
        "@io_k8s_apimachinery//pkg/api/errors:go_default_library",
        "@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
        "@io_k8s_apimachinery//pkg/runtime/schema:go_default_library",
        "@io_k8s_apimachinery//pkg/util/json:go_default_library",
        "@io_k8s_client_go//kubernetes:go_default_library",
        "@io_k8s_client_go//rest:go_default_library",
        "@io_k8s_client_go//tools/clientcmd:go_default_library",
        "@org_golang_google_grpc//:go_default_library",
        "@org_golang_google_grpc//codes:go_default_library",
        "@org_golang_google_grpc//status:go_default_library",
    ],
)

go_test(
    name = "go_default_test",
    srcs = [
        "error_test.go",
        "formatter_test.go",
        "label_test.go",
        "scheduled_workflow_test.go",
        "string_test.go",
        "template_util_test.go",
        "tgz_test.go",
        "workflow_test.go",
    ],
    embed = [":go_default_library"],
    deps = [
        "//backend/src/crd/pkg/apis/scheduledworkflow/v1beta1:go_default_library",
        "@com_github_argoproj_argo//pkg/apis/workflow/v1alpha1:go_default_library",
        "@com_github_ghodss_yaml//:go_default_library",
        "@com_github_stretchr_testify//assert:go_default_library",
        "@io_k8s_apimachinery//pkg/api/errors:go_default_library",
        "@io_k8s_apimachinery//pkg/apis/meta/v1:go_default_library",
        "@io_k8s_apimachinery//pkg/runtime/schema:go_default_library",
        "@io_k8s_apimachinery//pkg/types:go_default_library",
        "@io_k8s_kubernetes//pkg/apis/core:go_default_library",
        "@org_golang_google_grpc//codes:go_default_library",
    ],
)
